Ext.onReady(function(){
	// The login object is passed to the items collection.       
    var win = new Ext.Window({
        layout:'fit',
        width:300,
        height:150,
        closable: false,
        resizable: false,
        plain: true,
        border: false,
        items: [Ext.createWidget('form', { 
        	el: 'auth-form',
            autoShow: true,
            bodyPadding: '10',
            items: [{
                xtype: 'textfield',
                name: 'j_username',
                fieldLabel: CDR.I18N['login.username'],
                allowBlank:false ,
                anchor: '100%'
            }, {
                xtype: 'textfield',
                name: 'j_password',
                fieldLabel: CDR.I18N['login.password'],
                inputType:'password', 
                allowBlank:false ,
                anchor: '100%'
            }]
        })],
        buttons: [
          {
        	  formBind: true,
              text: CDR.I18N['button.login'],
              handler: function() {
                  Ext.get('auth-submit').dom.click();
              }
          }
      ]
	});
	win.show();
});